<div class="panel panel-default" ng-controller="BusTaskDetailCtrl">
	<div class="panel-heading">
		跨城巴士 / 司机任务 / 任务编号：{{task.taskNo}}
		<span style="float: right;margin-top: -7px;height: 0px">
			<button type="submit" class="btn m-b-xs w-xs btn-info" ui-sref="app.bus.task()">返回</button>
		</span>
	</div>
	<div class="row wrapper m-n">
		<div class="col-lg-12">
			<div class="panel panel-default">
				<div class="panel-body">任务详细</div>
			</div>
			<div class="table-responsive" style="margin-top:-20px">
				<table class="table table-striped b-t b-light">
					<tbody>
						<tr>
							<td>任务编号：{{task.taskNo}}</td>
							<td>任务类型：{{task.moduleId | moduleFilter}}</td>
							<td>任务创建时间：{{task.createTime | date : 'yyyy-MM-dd HH:mm:ss'}}</td>
						</tr>
						<tr>
							<td>任务状态：{{task.status | taskFilter}}</td>
							<td>是否当前任务：
								<span ng-if="task.current==true">是</span>
								<span ng-if="task.current==false">否</span></td>
							<td>分配司机：{{task.driver.name}}</td>
						</tr>
						<tr>
							<td>分配时间：{{task.assignTime | date : 'yyyy-MM-dd HH:mm:ss'}}</td>
							<td>开始时间：{{task.start | date : 'yyyy-MM-dd HH:mm:ss'}}</td>
							<td>结束时间：{{task.end | date : 'yyyy-MM-dd HH:mm:ss'}}</td>
						</tr>
						<tr>
							<td>始发城市：{{task.fromCity}}</td>
							<td>目的城市：{{task.toCity}}</td>
							<td>总历程：{{task.distance/1000 | number:2}}公里</td>
						</tr>
						<tr>
							<td>始发站：{{task.fromAddr}}</td>
							<td>目的站：{{task.toAddr}}</td>
	                        <td>总用时：{{task.duration}}分</td>
						</tr>
						<tr>
							<td>总乘客数：{{task.total}}人</td>
							<td>总检票数：{{task.checked}}</td>
							<td colspan="2">备注：{{task.remark}}</td>
						</tr>
					</tbody>
				</table>
			</div>
		</div>

		<div class="col-lg-12">
			<div class="panel panel-default">
				<div class="panel-body">司机信息</div>
			</div>
			<div class="table-responsive" style="margin-top:-20px">
				<table class="table table-striped b-t b-light">
					<thead>
						<tr>
							<th>司机编号</th>
							<th>司机姓名</th>
							<th>司机手机号</th>
							<th>当前状态</th>
							<th>所属组织</th>
						</tr>
					</thead>
					<tbody>
						<tr>
							<td>{{task.driver.code}}</td>
							<td>{{task.driver.name}}</td>
							<td>{{task.driver.phone}}</td>
							<td>{{task.driver.status | driverFilter }}</td>
							<td>{{task.driver.org.name}}</td>
						</tr>
					</tbody>
				</table>

			</div>
		</div>


		<div class="col-lg-12">
			<div class="panel panel-default">
				<div class="panel-body">班次信息<span style="color: red;">&nbsp （点击班次号即可跳转至班次详情页）</span></div>
			</div>
			<div class="table-responsive" style="margin-top:-20px">
				<table class="table table-striped b-t b-light">
					<thead>
						<tr>
							<th>班次号</th>
                            <th>班次状态</th>
                            <th>发车日期</th>
                            <th>发车时间</th>
                            <th>线路名</th>
						</tr>
					</thead>
					<tbody>
						<tr>
                            <td><a href tooltip="跳转至该班次详情" ui-sref="app.bus.shiftDetail({shiftId: task.shift.id})" target="_blank">{{task.shift.shiftNo}}</a></td>
                            <td>
					            <span ng-if="task.shift.status==0">等待发布</span>
					            <span ng-if="task.shift.status==1">等待报班</span>
					            <span ng-if="task.shift.status==2">等待发班</span>
					            <span ng-if="task.shift.status==3">运行中</span>
					            <span ng-if="task.shift.status==4">已完成</span>
					            <span ng-if="task.shift.status==5">晚点</span>
					            <span ng-if="task.shift.status==6">塌班</span>
					            <span ng-if="task.shift.status==7">被取消</span>	                               
                            </td>
                            <td>{{task.shift.departDate | date : 'yyyy-MM-dd'}}</td>
                            <td>{{task.shift.departTime | date : 'HH:mm:ss'}}</td>
                            <td>{{task.shift.routeName}}</td>
						</tr>
					</tbody>
				</table>
			</div>
		</div>

	</div>
</div>